package org.xiaofeipapa.feimall.userApi.controller;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.*;

/**
 */
@RestController
public class UserAuthController {

    @Value("${server.port}")
    private String serverPort;

    @GetMapping(value="/hello")
    private String hello(){
        return "我是 user service, 端口为： " + serverPort;
    }

    @GetMapping(value="/long_hello")
    private String longHello() throws Exception{
        Thread.sleep(10000);
        return "我是 user service, 用时10秒, 端口为： " + serverPort;
    }

//    @GetMapping(value="/hello")
//    private String hello(@RequestParam Long id){
//        return "我是 user service, 端口为： " + serverPort + " , id是: " + id;
//    }

}
